package com.huluobo.higt4demo1911.base;

import android.os.Bundle;

import androidx.annotation.ColorInt;
import androidx.annotation.Nullable;

import com.blankj.utilcode.util.BarUtils;
import com.blankj.utilcode.util.ScreenUtils;
import com.huluobo.higt4demo1911.core.mvp.BaseActivity;
import com.huluobo.higt4demo1911.core.mvp.IPresenter;

/**
 * Created by lc on 2022/4/26.
 * 1.全屏
 * 2.对应颜色状态栏
 * 3.沉浸式状态栏
 */
public abstract class StatusActivity<P extends IPresenter> extends BaseActivity<P> {
    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        initBar();
    }

    protected void fullScreen() {
        ScreenUtils.setFullScreen(this);
    }

    protected void statusBarColor(@ColorInt int color) {
        BarUtils.setStatusBarColor(this, color);
    }

    protected void statusTransBar() {
        BarUtils.transparentStatusBar(this);
    }

    protected abstract void initBar();
}
